package com.zzxx.service.impl;

import com.github.pagehelper.PageHelper;
import com.zzxx.domain.Orders;
import com.zzxx.mapper.OrdersMapper;
import com.zzxx.service.OrdersService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class OrdersServiceImpl implements OrdersService {
    @Autowired
    private OrdersMapper ordersMapper;
    @Override
    public List<Orders> queryAll(int pageNum, int pageSize) {
        PageHelper.startPage(pageNum, pageSize);
        return ordersMapper.findAll();
    }

    @Override
    public Orders queryById(String id) {
        return ordersMapper.findById(id);
    }


}
